<!DOCTYPE html>
<html>
<head>
    <title></title>
    <script type="text/javascript" src="../../../lib/jquery-1.8.3.js"></script>
</head>
<body>
<p>paragraph</p>
<div>division</div>
<script type="text/javascript">
    /**
     * 传入的element(p)上的事件Name:click
     * 使用了该API：stopImmediatePropagation之后
     * 后面针对该element 该事件name的handler都不再执行了。
     */
    $(document).ready(function(){
        $("p").click(function(event){
            // This function won't be executed
            $(this).css("border", "10px solid #000");
        });

        $("p").click(function(event){
            event.stopImmediatePropagation();
        });
        $("p").click(function(event){
            // This function won't be executed
            $(this).css("background-color", "#f00");
        });



        $("div").click(function(event) {
            // This function will be executed
            $(this).css("background-color", "#f00");
        });
    });
</script>
</body>
</html>